//
//  TopSegmentView.h
//  Marketing
//
//  Created by Hanen 3G 01 on 16/5/11.
//  Copyright © 2016年 Hanen 3G 01. All rights reserved.
//

#import <UIKit/UIKit.h>

@class TopSegmentView;
@protocol SegViewDelegate <NSObject>

- (void)segmentView:(TopSegmentView *)segment didSelectIndex:(NSInteger)index withTitle:(NSString *)btnTitlte;

- (void)segmentView:(TopSegmentView *)segment didScrollIndex:(NSInteger)index;
@end

@interface TopSegmentView : UIView
//- (instancetype)initWithFrame:(CGRect)frame;
@property (nonatomic, strong) UIButton *rightBtn;
@property (nonatomic, strong) UIButton *leftBtn;
@property (nonatomic, strong) NSString * leftTitle;
@property (nonatomic, strong) NSString * rightTitle;

@property (nonatomic, strong) NSAttributedString * leftAttributeStr;
@property (nonatomic, strong) NSAttributedString * rightAttributeStr;

@property (nonatomic, assign)int selectIndex;

@property (nonatomic, strong) NSArray *titles;


//默认选中的
@property (nonatomic, assign) NSInteger firstIndex;

//指示器的颜色
@property (nonatomic, strong) UIColor *indicatorViewColor;

//代理
@property (nonatomic, weak)id <SegViewDelegate>delegate;
@end
